package com.woniuxy.coachmodel.form;

import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;

@Data
public class CoachRegisterForm {



    @NotBlank(message = "教练姓名不能为空")
    @Size(min = 2, max = 20, message = "教练姓名长度必须在2到20之间")
    private String coachName;

    @NotBlank(message = "身份证不能为空")
    @Pattern(regexp = "\\d{17}[\\d|x|X]", message = "身份证格式不正确")
    private String idCard;

    @NotBlank(message = "账号不能为空")
    @Size(min = 6, max = 20, message = "账号长度必须在6到20之间")
    private String coachAccount;

    @NotBlank(message = "密码不能为空")
    @Size(min = 6, max = 20, message = "密码长度必须在6到20之间")
    private String coachPass;

    @NotBlank(message = "电话不能为空")
    @Pattern(regexp = "1[3-9]\\d{9}", message = "电话格式不正确")
    private String coachPhone;

    @NotBlank(message = "验证码不能为空")
    @Pattern(regexp = "\\d{6}", message = "验证码必须是6位数字")
    @Size(min = 6, max = 6, message = "验证码长度必须为6位")
    private String phoneCode;
    @NotBlank(message = "头像不能为空")
    private String coachAvatar;
    @NotBlank(message = "简介不能为空")
    private String coachRemark;
    @NotBlank(message = "执照不能为空")
    private String coachLicense;



}
